package com.pym;

import com.pym.base.model.PageParams;
import com.pym.base.model.PageResult;
import com.pym.content.model.dto.CourseCategoryTreeDto;
import com.pym.content.model.dto.QueryCourseParamsDto;
import com.pym.content.model.po.CourseBase;
import com.pym.content.service.CourseBaseInfoService;
import com.pym.content.service.CourseCategoryService;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;

import java.util.List;

@SpringBootTest
public class test {
    @Autowired
    private CourseBaseInfoService courseBaseInfoService;

    @Autowired
    private CourseCategoryService courseCategoryService;


    @Test
    void text1(){

        PageParams pageParams = new PageParams();

        PageResult<CourseBase> courseBasePageResult = courseBaseInfoService.queryCourseBaseList(pageParams, new QueryCourseParamsDto());
        System.out.println(courseBasePageResult);
    }
    @Test
    void text2(){

        List<CourseCategoryTreeDto> categoryTreeDtos = courseCategoryService.queryTreeNodes("1");
        System.out.println(categoryTreeDtos);
    }
}
